<template>
	<view>
		<view>数据绑定的学习</view>
		<view>{{message}}</view>
		<view>{{1+'你好'}}</view>
		<view>{{1+1}}</view>
		<view>{{flag ? '真的' : '假的'}}</view>
		<image :src="imgUrl"></image>
		<view v-for="(item, index) in arr" :key="item.id">
			序号：{{index}},名字：{{item.name}}，年龄：{{item.age}}
		</view>
		<button type="primary" @click="clickHandle(20, $event)">按钮</button>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				message: 'hello',
				flag: true,
				imgUrl: "../../static/tabs/contact-active.png",
				arr: [
					{
						name: 'kk',
						age: 23,
						id: 1
					},
					{
						name: 'ykk',
						age: 22,
						id: 2
					},
					{
						name: 'hhk',
						age: 21,
						id: 3
					},
					{
						name: 'hkhk',
						age: 33,
						id: 4
					},
				]
			}
		},
		methods: {
			clickHandle (num, e) {
				console.log(num, e)
			}
		}
	}
</script>

<style>
</style>
